package com.bigfish.gbs.dto;

import com.bigfish.gbs.entity.Supplier;
import com.bigfish.gbs.entity.User;

import java.io.Serializable;
import java.util.Date;

/**
 * @Author Joycessh
 * @Description
 * @Date 12/18/18 9:50 AM
 */
public class SupplierVO implements Serializable {

    private String userId;

    private String username;

    private String password;

    private String salt;

    private String realName;

    private Byte sex;

    private String phone;

    private String mail;

    private String avator;

    private Byte status;

    private Date createTime;

    private Date updateTime;

    private String supplierName;

    private String address;

    private String description;


    public SupplierVO(){}



    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getSalt() {
        return salt;
    }

    public void setSalt(String salt) {
        this.salt = salt;
    }

    public String getRealName() {
        return realName;
    }

    public void setRealName(String realName) {
        this.realName = realName;
    }

    public Byte getSex() {
        return sex;
    }

    public void setSex(Byte sex) {
        this.sex = sex;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getMail() {
        return mail;
    }

    public void setMail(String mail) {
        this.mail = mail;
    }

    public String getAvator() {
        return avator;
    }

    public void setAvator(String avator) {
        this.avator = avator;
    }

    public Byte getStatus() {
        return status;
    }

    public void setStatus(Byte status) {
        this.status = status;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public String getSupplierName() {
        return supplierName;
    }

    public void setSupplierName(String supplierName) {
        this.supplierName = supplierName;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public User getUser(){
        User user = new User();
        user.setUserId(this.userId);
        user.setPassword(this.password);
        user.setUsername(this.username);
        user.setSalt(this.salt);
        user.setRealName(this.realName);
        user.setMail(this.mail);
        user.setPhone(this.phone);
        user.setSex(this.sex);
        user.setStatus(this.status);
        return user;

    }

    public Supplier getSupplier() {
        Supplier supplier = new Supplier();
        supplier.setUserId(this.userId);
        supplier.setAddress(this.address);
        supplier.setSupplierName(this.supplierName);
        supplier.setDescription(this.description);
        return supplier;
    }
}
